#!/bin/bash
# 本地打包
make docker

# api 打包
docker build -t proxy-api ./
docker tag proxy-api registry.cn-hangzhou.aliyuncs.com/jindai/proxy-api:latest
docker push registry.cn-hangzhou.aliyuncs.com/jindai/proxy-api:latest

# service-wechat 打包
docker build -f ./services/wechat/Dockerfile -t service-wechat .
docker tag service-wechat registry.cn-hangzhou.aliyuncs.com/jindai/service-wechat:latest
docker push registry.cn-hangzhou.aliyuncs.com/jindai/service-wechat:latest

# service-user 打包
docker build -f ./services/user/Dockerfile -t service-user .
docker tag service-user registry.cn-hangzhou.aliyuncs.com/jindai/service-user:latest
docker push registry.cn-hangzhou.aliyuncs.com/jindai/service-user:latest

# service-music 打包
docker build -f ./services/music/Dockerfile -t service-music .
docker tag service-music registry.cn-hangzhou.aliyuncs.com/jindai/service-music:latest
docker push registry.cn-hangzhou.aliyuncs.com/jindai/service-music:latest

echo "push aliyun success"